package com.djx.gateway.exception;

import com.djx.common.result.Result;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.ExceptionHandler;

@Component
@Slf4j
public class ExceptionQuanju {
    @ExceptionHandler(Exception.class)
    public Result exceptionQuanju(Exception e){
        log.error("异常信息：{}",e.getMessage());
        return Result.error("出现问题请及时联系管理员");
    }
}
